package com.baiyun.stock.pojo.domain;

import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.math.BigDecimal;
import java.util.Date;

@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
@ApiModel(description = "股票涨跌信息实体封装")
public class StockUpdownDomain {

    @ExcelProperty(value = {"股票涨幅信息统计表","股票代码"},index = 0)
    @ApiModelProperty(value = "股票代码",name = "code")
    private String code;

    @ExcelProperty(value = {"股票涨幅信息统计表","股票名称"},index = 1)
    @ApiModelProperty(value = "股票名称",name = "name")
    private String name;

    @ExcelProperty(value = {"股票涨幅信息统计表","前收盘价"},index = 2)
    @ApiModelProperty(value = "前收盘价",name = "preClosePrice")
    private BigDecimal preClosePrice;

    @ExcelProperty(value = {"股票涨幅信息统计表","当前价"},index = 3)
    @ApiModelProperty(value = "当前价",name = "tradePrice")
    private BigDecimal tradePrice;

    @ExcelProperty(value = {"股票涨幅信息统计表","涨跌"},index = 4)
    @ApiModelProperty(value = "涨跌",name = "increase")
    private BigDecimal increase;

    @ExcelProperty(value = {"股票涨幅信息统计表","涨幅"},index = 5)
    @ApiModelProperty(value = "涨幅",name = "upDown")
    private BigDecimal upDown;

    @ExcelProperty(value = {"股票涨幅信息统计表","振幅"},index = 6)
    @ApiModelProperty(value = "振幅",name = "amplitude")
    private BigDecimal amplitude;

    @ExcelProperty(value = {"股票涨幅信息统计表","成交量"},index = 7)
    @ApiModelProperty(value = "成交量",name = "tradeAmt")
    private Long tradeAmt;

    @ExcelProperty(value = {"股票涨幅信息统计表","成交额"},index = 8)
    @ApiModelProperty(value = "交易额",name = "tradeVol")
    private BigDecimal tradeVol;

    /**
     * 日期
     */
    @ExcelProperty(value = {"股票涨幅信息统计表","日期"},index = 9)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    @ApiModelProperty(value = "日期 || 格式 yyyy-MM-dd HH:mm",name = "curDate")
    private Date curDate;
}